import pymysql
from fastapi import FastAPI,Form

app=FastAPI()
@app.post("/xiugai")
def hhh(id:int=Form(...)):
    conn=pymysql.Connection(user="root",password="Zly123456.",database="zhang")
    cursor=conn.cursor()
    cursor.execute("update score set status='停售' where id=%s",(id,))
    conn.commit()
    return {"info":"修改成功"}